<%@page import="com.mmy.domain.sys.TSysUser"%>
<%@page import="com.mmy.domain.constzone.TConstZone"%>
<%@page import="com.mmy.domain.line.TLineBase"%>
<%@page import="com.mmy.domain.sys.TSysOrg"%>
<%@page import="com.mmy.domain.line.TLinePlace"%>
<%@page import="com.mmy.domain.line.TLineTrip"%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<% TSysUser tSysUser = (TSysUser) session.getAttribute("tSysUser");%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<jsp:include page="/WEB-INF/jsp/includeb.jsp"></jsp:include>
<script type="text/javascript" src="js/jsp/back/surroud/createSurroud.js"></script>
<title>新建线路</title>
</head>
<body>
	<div id="off-canvas-container" class="off-canvas-container">
		<jsp:include page="/WEB-INF/jsp/BackHeader.jsp"></jsp:include>
		<main class="at-padding-large-bottom"> 
		<article> 
		<header class="bg-light at-padding-large-top at-padding-large-bottom at-margin-large-bottom">
		<div class="page-header container">
			<div class="row">
				<div class="span-5 col">
					<h1>线路管理</h1>
				</div>
			</div>
		</div>
		</header> <section class="container"> <!-- 新建线路基本信息 -->
		<div class="information">
			<form id="createForm">
				<input type="hidden" id="type" value="${type}">
				<h4 class="info-h4">
					<i class="fa fa-caret-right" aria-hidden="true"></i>新建线路信息
				</h4>
				<div class="input-container">
					<table class="info-table" id="LineBase">
						<tr>
							<th><label for="LineName">线路名称</label><span class="mustWrite">*</span></th>
							<td colspan="5"><input type="text" id="LineName" class="easyui-validatebox" name="LineName"/>
							</td>
						</tr>
						<tr>
							<th>所属区域<span class="mustWrite">*</span></th>
							<td>
							<c:choose>
							<c:when test="${type == 3 }">
									<select class="input-select-vlign  select-height" id="visaZoneID" name="Continent" emptyOption="false"  onchange="changeSelect(this,'getLevel2','level1','Country')"  required>
										<option value="">---请选择---</option>
										<c:forEach var="lstZoneContinent" items="${lstZoneContinent}">
										<option value="${lstZoneContinent.getZoneID()}">${lstZoneContinent.getZoneName()}</option>
										</c:forEach>
									</select>
									<select class="input-select-vlign select-height Country" name="country" id="dist" emptyOption="false"  required>
									<option value="">---请选择---</option>
									</select>			
							</c:when>
							<c:otherwise>
										<input id="prov" name="province">
										<input id="citi" name="city">
										<input id="dist" name="dist">
							</c:otherwise>
							</c:choose>
							</td>
						</tr>
						<!-- 集合地，时间 -->
						<tr>
							<th><label for="LinePlace">集合地点与时间</label><span class="mustWrite">*</span></th>
							<td id="placeTime" colspan="5">
								<div id="place0">
									地点：
									<input id="placeName0" type="text" list="PlaceNameList">
									<datalist id="PlaceNameList">
										<c:forEach var="lstLinePlace" items="${lstLinePlace}">
													<option>${lstLinePlace.getPlaceName()}</option>
										</c:forEach>
									</datalist>
									时间：<input type="text" id="placeTime0" name="placeTime" maxlength="128" /> 
										<input type="button" class="btn" value="增加"  onClick="addPlaceTables()">
								</div>
							</td>
							<!-- 增加行到这里 -->
						</tr>
						
						<!-- 	上传行程单 -->
						<tr>
							<th><label for="LineItineraryPath">行程单</label><span
								class="mustWrite">*</span></th>
							<td colspan="5"><input type="file" id="LineItineraryPath" name="ItineraryPath"/></td>
						</tr>
						<tr>
							<th><label for="LineOwn">自费项目</label><span class="mustWrite">*</span></th>
							<td colspan="5"><textarea id="LineOwn" name="Own" ></textarea>
							</td>
						</tr>
						<tr>
							<th><label for="LineTips">温馨提示</label><span class="mustWrite">*</span></th>
							<td colspan="5"><textarea id="LineTips" name="Tips"></textarea>
							</td>
						</tr>
						<tr>
							<th><label for="LineStandard">接待标准</label><span class="mustWrite">*</span></th>
							<td colspan="5"><textarea id="LineStandard" name="Standard"
									required="required"></textarea>
							</td>
						</tr>
						<tr>
							<th><label for="LineExplain">接待说明</label><span class="mustWrite">*</span></th>
							<td colspan="5"><textarea id="LineExplain" name="Explain"
									required="required"></textarea>
							</td>
						</tr>
						<tr>
							<th><label for="LineMemo">备注</label></th>
							<td colspan="5"><textarea id="LineMemo" name="Memo"></textarea>
							</td>
						</tr>
					</table>
				</div>
				<!-- 创建行程信息 -->
				<h4 class="info-h4">
					<i class="fa fa-caret-right" aria-hidden="true"></i>新建行程信息
				</h4>
				<div class="input-container">
					<table id="tripTable" class="info-table">
						<tbody>
							<tr>
								<td colspan="7">详情</td>
								<td>操作</td>
							</tr>
						</tbody>
					</table>
					<input type="button" id="btn_addtr" class="btn" value="增行"
						onClick="addTripTables()">
				</div>
				<center>
					<input type="button" class="btn" value="保存" id="btn_tripaddtr" onclick="saveCreateSurrounding()" /> 
					<input type="button" class="btn" value="返回" onclick="rehidder()" />
				</center>
			</form>
		</div>
	</div>
	</section>
	</article>
	</main>
	<jsp:include page="/WEB-INF/jsp/Footer.jsp"></jsp:include>
	</div>
	<jsp:include page="/WEB-INF/jsp/include2.jsp"></jsp:include>
</body>
</html>